/* 
    存储接口请求的域名
*/

import http from "./index";

let url;

if (process.env.NODE_ENV == "development") {
  // 开发环境中
  url = "http://192.168.119.3:11329";
} else {
  // 生产环境中
  url = "http://127.0.0.1:8002";
}

// 登陆
export const login = (params) =>
  http.postRequest(url + "/login/web/signIn", params);
//登录滑块验证
export const ImgAuth = (params) =>
  http.postRequest(url + "/login/web/imgAuth", params);
//回去图片滑块
export const slideImgCoden = (params) =>
  http.getRequest(url + "/login/web/slideImgCode", params);

export default {
  url,
  login,
  slideImgCoden,
  ImgAuth,
};
